package com.rran.study.designpattern.behavioral.observer.event.app;

/**
 * @author yy
 * @Type AppEvent.java
 * @Desc
 * @date 2020/7/21 18:34
 */
public abstract class AppEvent {

    protected Object source;

    public abstract String getEventName();

    public AppEvent(Object source) {
        if (source == null) {
            throw new IllegalArgumentException("null source");
        }
        this.source = source;
    }

    public Object getSource() {
        return source;
    }
}
